/*
 * --- Variables y Reset ---
 */
:root {
    /* Paleta de Colores */
    --color-primary: #3498db;
    /* Azul vibrante para acentos y botones */
    --color-secondary: #0eadecc0;
    /* Azul oscuro para texto principal y fondos */
    --color-background-light: #f4f4f9;
    /* Fondo claro para el cuerpo */
    --color-text-dark: #333;
    /* Color de texto estándar */
    --color-text-light: #ecf0f1;
    /* Texto claro para fondos oscuros */
    --color-accent-soft: #e8f5ff;
    /* Fondo muy claro para secciones */
    --color-border: #ddd;

    /* Tipografía */
    --font-primary: 'Helvetica Neue', Helvetica, Arial, sans-serif;
    --font-serif: 'Georgia', serif;

    /* Espaciado */
    --spacing-unit: 1rem;
    --max-width: 2000px;
}

/* Reset básico */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: var(--font-primary);
    line-height: 1.6;
    color: var(--color-text-dark);
    background-color: var(--color-background-light);
    padding-top: 50px;  /* Espacio para una barra de navegación si se añade */
    display: flex;
    flex-direction: column;
    min-height: 100vh;
}

/*
 * --- Encabezado (Header) y Portada ---
 */
.cover-section {
    background-color: var(--color-secondary);
    color: var(--color-text-light);
    padding: calc(2 * var(--spacing-unit)) 0;
    text-align: center;
}

.cover-image-container {
    max-width: var(--max-width);
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: calc(2 * var(--spacing-unit));
    padding: 0 var(--spacing-unit);
}

.book-cover {
    width: 200%;
    max-width: 250px;
    height: auto;
    border-radius: 8px;
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.3);
    transition: transform 0.3s ease;
}

.book-cover {
    width: 200%;
    max-width: 250px;
    height: auto;
    border-radius: 8px;
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.3);
    transition: transform 0.3s ease;
    /* --- AÑADE ESTA LÍNEA PARA INCLINAR LA IMAGEN --- */
    transform: rotate(-5deg);
    /* rotar imagen */
}

.book-cover:hover {
    /* ACTUALIZA ESTA LÍNEA: Combina la rotación con el efecto translateY */
    transform: translateY(-5px) rotate(-3deg);
}

.book-title {
    font-family: var(--font-serif);
    font-size: 2.5rem;
    margin-top: 0;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.5);
}

/*
 * --- Contenido Principal (Main) --- */
.content-container {
    max-width: 900px;
    margin: 0 auto;
    padding: calc(3 * var(--spacing-unit)) var(--spacing-unit);
    width: 100%;
}

.content-section {
    margin-bottom: calc(4 * var(--spacing-unit));
    width: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
}
h2 {
    font-size: 2rem;
    color: var(--color-primary);
    margin-bottom: calc(1.5 * var(--spacing-unit));
    text-align: center;
    border-bottom: 2px solid var(--color-primary);
    padding-bottom: 0.5rem;
    margin-top: 0;
}

p {
    margin-bottom: var(--spacing-unit);
    text-align: justify;
}

hr {
    border: none;
    border-top: 1px solid var(--color-border);
    margin: calc(4 * var(--spacing-unit)) 0;
}

/*
 * --- Temas Clave (Topics Grid) --- */
.topics-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: calc(2 * var(--spacing-unit));
    margin-top: calc(3 * var(--spacing-unit));
}

.topic-card {
    background-color: white;
    padding: calc(2 * var(--spacing-unit));
    border-radius: 10px;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    border-top: 4px solid var(--color-primary); /* Base color */
}

.topic-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 15px rgba(0, 0, 0, 0.15);
}

.topic-card h3 {
    font-size: 1.3rem;
    color: var(--color-secondary);
    margin-top: 0;
    margin-bottom: var(--spacing-unit);
}

/* Paleta de colores para las tarjetas (opcional) */
.fertility {
    border-top-color: #9b59b6; /* violet*/
    }

.treatments {
    border-top-color: #2ecc71; /* verd */
 }
.adoption {
    border-top-color: #2ecc71; /* Verde */
     }
.laws {
    border-top-color: #9b59b6; /* violet */
}    


.buy-button {
    display: inline-block;
    background-color: var(--color-primary);
    color: var(--color-text-light);
    text-decoration: none;
    padding: 1rem 2rem;
    margin-top: var(--spacing-unit);
    border-radius: 50px;
    font-weight: bold;
    font-size: 1.1rem;
    letter-spacing: 1px;
    transition: background-color 0.3s ease, transform 0.1s ease;
}

.buy-button:hover {
    background-color: #2980b9;
    /* Tono de azul más oscuro */
}

.buy-button:active {
    transform: scale(0.98);
}

/*
 * --- Pie de página (Footer) ---
 */
footer {
    background-color: var(--color-secondary);
    color: var(--color-text-light);
    text-align: center;
    padding: var(--spacing-unit) 0;
    font-size: 0.9rem;
    border-top: 5px solid var(--color-primary);
}

/*
 * --- Media Queries (Responsividad) --- */

/* Pequeñas pantallas (móviles) */
@media (max-width: 768px) {
    .book-title {
        width: 100%;
        font-size: 2rem;
        max-width: none;
        margin: 0;
        padding: 25px 15px;
        border-radius: o;
        box-shadow: none;

    }

    h2 {
        font-size: 1.7rem;
    }

    .topics-grid {
        grid-template-columns: 1fr;  /* Una columna en pantallas pequeñas */
    }

    .cover-section {
        padding: calc(2 * var(--spacing-unit)) 0;
    }

    .book-cover {
        max-width: 200px;

    }
}

/* Pantallas medianas y grandes */
@media (min-width: 900px) {
    .cover-image-container {
        flex-direction: row;
        text-align: left;
        align-items: center;
        justify-content: center;
        gap: calc(4 * var(--spacing-unit));
    }

    .book-title {
        font-size: 3rem;
        text-align: left;
    }
}

/* Estilos para el formulario de contacto */
.contacto-form form {
    display: flex;
    flex-direction: column;
    gap: 18px;
    width: 100%;
    margin: 0 auto;
}

.contacto-form .form-group label {
    display: block;
    margin-bottom: 5px;
    font-weight: bold;
}

.contacto-form .form-group input,
.contacto-form .form-group textarea {
    width: 100%;
    padding: 10px;
    border: 1px solid  #a30f72;
    border-radius: 5px;
     color: #a30f72 ;
    box-sizing: border-box;
}

.contacto-form{
    width: 100%;
    max-width: 550px;
    margin: 40px auto;
    padding: 30px 25px;
    border-radius: 10px;
    box-sizing: border-box;

}

.contacto-form textarea {
    resize: vertical;
}


.contacto-form button {
    padding: 10px 15px;
    background-color: #a30f72;  /* Un violet para el botón */
    color: white;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    font-size: 1em;
    transition: background-color 0.3s ease;
}